package com.ruoyi.outbound.domain;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;

/**
 * #订单信息表
 * @TableName bm_inorderlist
 */
@Data
public class BmInorderlist implements Serializable {
    /**
     * 订单编号
     */
    private String orderCode;

    /**
     * 店铺id
     */

    private String businessName;
    private String warehouseName;
    private String wuliuName;
    private Integer sellerId;

    /**
     * 配送费
     */
    private BigDecimal deliveryFee;

    /**
     * 订单金额
     */
    private BigDecimal amount;

    /**
     * 支付方式 1.货到付款 2.在线支付
     */
    private Integer payType;

    /**
     * 订单步骤 待支付=1 已支付，待配货=2 已配货，待验货=3 已验货，待装货=4 已装货，待发货=5，已发货，待交货=6 已交货=7
     */
    private Integer orderStep;

    /**
     * 配送地址id
     */
    private String deliveryAddressId;

    /**
     * 订单创建时间
     */
    private Date createTime;

    /**
     * 支付时间
     */
    private Date payTime;

    /**
     * 订单状态 已取消=0 正常订单=1 已经完成=2 取消中=3 超时=4
     */
    private Integer orderState;

    /**
     * 订单配送步骤记录
     */
    private String orderStepRecord;

    /**
     * 仓库管理人员id
     */
    private Integer warehouserId;

    /**
     * 物流人员id
     */
    private Integer logisticsId;

    /**
     * 订单备注
     */
    private String mark;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        BmInorderlist other = (BmInorderlist) that;
        return (this.getOrderCode() == null ? other.getOrderCode() == null : this.getOrderCode().equals(other.getOrderCode()))
            && (this.getSellerId() == null ? other.getSellerId() == null : this.getSellerId().equals(other.getSellerId()))
            && (this.getDeliveryFee() == null ? other.getDeliveryFee() == null : this.getDeliveryFee().equals(other.getDeliveryFee()))
            && (this.getAmount() == null ? other.getAmount() == null : this.getAmount().equals(other.getAmount()))
            && (this.getPayType() == null ? other.getPayType() == null : this.getPayType().equals(other.getPayType()))
            && (this.getOrderStep() == null ? other.getOrderStep() == null : this.getOrderStep().equals(other.getOrderStep()))
            && (this.getDeliveryAddressId() == null ? other.getDeliveryAddressId() == null : this.getDeliveryAddressId().equals(other.getDeliveryAddressId()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getPayTime() == null ? other.getPayTime() == null : this.getPayTime().equals(other.getPayTime()))
            && (this.getOrderState() == null ? other.getOrderState() == null : this.getOrderState().equals(other.getOrderState()))
            && (this.getOrderStepRecord() == null ? other.getOrderStepRecord() == null : this.getOrderStepRecord().equals(other.getOrderStepRecord()))
            && (this.getWarehouserId() == null ? other.getWarehouserId() == null : this.getWarehouserId().equals(other.getWarehouserId()))
            && (this.getLogisticsId() == null ? other.getLogisticsId() == null : this.getLogisticsId().equals(other.getLogisticsId()))
            && (this.getMark() == null ? other.getMark() == null : this.getMark().equals(other.getMark()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getOrderCode() == null) ? 0 : getOrderCode().hashCode());
        result = prime * result + ((getSellerId() == null) ? 0 : getSellerId().hashCode());
        result = prime * result + ((getDeliveryFee() == null) ? 0 : getDeliveryFee().hashCode());
        result = prime * result + ((getAmount() == null) ? 0 : getAmount().hashCode());
        result = prime * result + ((getPayType() == null) ? 0 : getPayType().hashCode());
        result = prime * result + ((getOrderStep() == null) ? 0 : getOrderStep().hashCode());
        result = prime * result + ((getDeliveryAddressId() == null) ? 0 : getDeliveryAddressId().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getPayTime() == null) ? 0 : getPayTime().hashCode());
        result = prime * result + ((getOrderState() == null) ? 0 : getOrderState().hashCode());
        result = prime * result + ((getOrderStepRecord() == null) ? 0 : getOrderStepRecord().hashCode());
        result = prime * result + ((getWarehouserId() == null) ? 0 : getWarehouserId().hashCode());
        result = prime * result + ((getLogisticsId() == null) ? 0 : getLogisticsId().hashCode());
        result = prime * result + ((getMark() == null) ? 0 : getMark().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", orderCode=").append(orderCode);
        sb.append(", sellerId=").append(sellerId);
        sb.append(", deliveryFee=").append(deliveryFee);
        sb.append(", amount=").append(amount);
        sb.append(", payType=").append(payType);
        sb.append(", orderStep=").append(orderStep);
        sb.append(", deliveryAddressId=").append(deliveryAddressId);
        sb.append(", createTime=").append(createTime);
        sb.append(", payTime=").append(payTime);
        sb.append(", orderState=").append(orderState);
        sb.append(", orderStepRecord=").append(orderStepRecord);
        sb.append(", warehouserId=").append(warehouserId);
        sb.append(", logisticsId=").append(logisticsId);
        sb.append(", mark=").append(mark);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}